package com.bw.paper.mvp.view.Fragment;

import android.os.Bundle;

import androidx.fragment.app.Fragment;
import androidx.viewpager.widget.ViewPager;

import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import com.bw.paper.mvp.view.Fragment.video.Adapter.VideoVpAdapter;
import com.bw.paper.R;
import com.flyco.tablayout.SlidingTabLayout;

public class VideoFragment extends Fragment {



    public VideoFragment() {
        // Required empty public constructor
    }

    private View rootView;
    private SlidingTabLayout video_tab;
    private ViewPager video_vp;
    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container,
                             Bundle savedInstanceState) {
        rootView = inflater.inflate(R.layout.fragment_video,container,false);
        init();
        return rootView; }

    private void init(){
        video_tab = rootView.findViewById(R.id.video_tab);
        video_vp = rootView.findViewById(R.id.video_vp);
        video_vp.setAdapter(new VideoVpAdapter(getFragmentManager()));
        video_tab.setViewPager(video_vp);
    }
}